package com.zzx.threekingdom.model;

public class Damage
{
    public int damage = 0;
    public ActionInfo mActionInfo = null;
    
    public Damage(ActionInfo act)
    {
    	mActionInfo = act;
        damage = getDamageByAction();
    }
    
    public void doDamage(AbsPlayerModel targetPm, Runnable doneR) { targetPm.onDamage(this, doneR); }
    
    public int getDamage() { return damage; };
    
    public int getDamageByAction()
    {
    	if(mActionInfo == null)
    		return 0;
    	else if(mActionInfo.getActionName().equals("闪电"))
    		return 3;
    	
    	return 1;
    }

}
